#include<stdio.h>
#define N 2
int main()
{
	struct stu
	{
		long int num;
		char name[20];
		int age;
		float English;
		float math;
		float Chinese;
		float politics;
		float physics;
		float chemistry;
		float computer;
		float total;
		float ave;
	}s[N];
	int sz = sizeof(s) / sizeof(s[0]);
	float max = 0;
	int flag = 0;
	for (int i = 0; i < sz; i++)
	{
		scanf_s("%d", &s[i].num);
		scanf_s(" %s",s[i].name,20);
		scanf_s("%d",&s[i].age);
		scanf_s("%f%f%f%f%f%f%f", &s[i].English, &s[i].math, &s[i].Chinese, &s[i].politics, &s[i].physics, &s[i].chemistry, &s[i].computer);
	}
	for (int i = 0; i < sz; i++)
	{
		s[i].total = s[i].English + s[i].math + s[i].Chinese + s[i].politics + s[i].physics + s[i].chemistry + s[i].computer;
		s[i].ave = s[i].total / 7;
	}
	max = s[0].total;
	for (int i = 0; i < sz; i++)
	{
		if (max < s[i].total)
			flag = i;
	}
	printf("%s\n", s[flag].name);
	return 0;
}